package main

import (
	"demo02/retriever/mock"
	real2 "demo02/retriever/real"
	"fmt"
	"time"
)

type Retriver interface {
	Get(url string) string
}

func main() {
	var r Retriver
	r = mock.Retriver{"这是一个测试目录"}

	fmt.Printf("%T %v \n", r, r)
	r = &real2.Retriever{
		UserAgent: "Mozilla/5.0",
		TimeOut:   time.Microsecond,
	}
	fmt.Println(r.Get("http://www.baidu.com"))
}
